<%@page language="C#" Debug="true" %>
<%@import namespace="System.Collections.Generic" %>
<%@import namespace="System.Data" %>
<%@import namespace="My" %>
<%@import namespace="My.Data.Worker" %>

<script runat="server">

    // 成员数据
    //private string _tbStat = "stat";
    
    // 当前页数
    public int pageCurr = 1;
    
    
    // 入口
    protected void Page_Load (object sender, System.EventArgs e)
    {
        string connectionString = ConfigurationManager.ConnectionStrings["stat.programmingcanruinyourlife.cn"].ConnectionString.ToString();
        
        pageCurr = My.Convert.ToInt(  Request.QueryString["page"]  );
        // DbUtil.ConnectionString = connectionString;
        // string sql = "Select * from " + _tbStat + " Order By Id Desc";
        // DataTable table = DbUtil.Select(sql);
        
        WebStat stat = new WebStat(connectionString);
				stat.PageSize = 100;
				stat.CurrentPage = pageCurr;
				
        Response.Write (  stat.Sql.Query(stat.PageSize, stat.CurrentPage) + "<br /><br />"  );
        DataTable table = stat.Query(stat.PageSize, stat.CurrentPage);
        
        //Response.Write (WebUI.PageNav(stat.RecordCount, stat.PageSize, stat.CurrentPage, "?"));
        My.Web.Web.Print(table);
        // foreach (  DataRow row in table.Rows  )
        // {
        //     Response.Write (  Server.UrlDecode(row["referrer"].ToString())+ "||||"  );
        //     Response.Write (  row["page"].ToString()+ "<br />"  );
        // }
        
        //Response.Write (WebUI.PageNav(stat.RecordCount, stat.PageSize, stat.CurrentPage, "?"));
    }
    



</script>

